﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace 圆
{

    class Program
    {
        static void Main(string[] args)
        {
            Yuan yuan = new Yuan();
            yuan.r = 3f;

            //周长
            Console.WriteLine(yuan.Got());

            //面积
            Console.WriteLine(yuan.Get());
        }
    }

     class Yuan
    {

        //定义一个π
        public  float π = 3.14f;

        //public const float π = 3.14f;

        //定义半径
        public float r;

        //算周长
        public float Got()
        {
            return (2 * r * π);
        }

        //算面积
        public float Get()
        {
            return (π * r * r);
        }
    }
}
